function changeTheme(systemId) {
    console.log(systemId);
    if (typeof systemId !== 'string') {
        systemId = systemId.toString();
    }
    var themeMap = {
        //爱润妍
        10: {
            main: '#bf2071',
            sec: '#28163D',
            third: '#5A124A',
            tabIcon: '#fff'
        },
        //倩妆
        20: {
            main: '#b62b2e',
            sec: '#fff',
            third: '#b62b2e',
            tabIcon: '#666'
        },
        //母婴
        30: {
            main: '#66843F',
            sec: '#fff',
            third: '#66843F',
            tabIcon: '#666'
        },
        //聚合
        99: {
            main: '#bf2071',
            sec: '#28163D',
            third: '#5A124A',
            tabIcon: '#fff'
        }
    };

    // 读取数据
    // const rootStyles = getComputedStyle(document.documentElement);
    // const varValue = rootStyles.getPropertyValue('--MAIN-COLOR').trim();

    // 根据系统号切换主题色

    let themeId = systemId.toString().charAt(0) + systemId.toString().charAt(1);
    document.documentElement.style.setProperty('--MAIN-COLOR', themeMap[themeId || 10].main);
    document.documentElement.style.setProperty('--SEC-COLOR', themeMap[themeId || 10].sec);
    document.documentElement.style.setProperty('--THR-COLOR', themeMap[themeId || 10].third);
    document.documentElement.style.setProperty('--TAB-ICON-COLOR', themeMap[themeId || 10].tabIcon);
}

let system = JSON.parse(localStorage.getItem('system'));
if (system) {
    changeTheme(system);
}
